package com.java.day07.weapons;

/**
 * 长剑
 */
public class LongSword extends Weapons{

    //暴击
    private int criticalStrike;

    //格挡
    private int block;


    //构造方法
    public LongSword() {
    }

    public LongSword(String name, int atack, int durability, int criticalStrike, int block) {
        super(name, atack, durability);
        this.criticalStrike = criticalStrike;
        this.block = block;
    }

    public int getCriticalStrike() {
        return criticalStrike;
    }

    public void setCriticalStrike(int criticalStrike) {
        this.criticalStrike = criticalStrike;
    }

    public int getBlock() {
        return block;
    }

    public void setBlock(int block) {
        this.block = block;
    }

    @Override
    public String toString() {
        return "LongSword{" +
                "criticalStrike=" + criticalStrike +
                ", block=" + block +
                ", name='" + getName() + '\'' +
                ", atack=" + getAtack() +
                ", durability=" + getDurability() +
                '}';
    }
}
